<!--<template lang="">
    <div>
        来自父组件的消息:{{msg}}
    </div>
</template>
<script>
export default {
    props:["msg"]
};
</script>
<style lang="">
    
</style>-->

<template lang="">
    <div>
        <p>姓名:{{name}}</p>
         <p>年龄:{{age}}</p>
          <p>性别:{{gender}}</p>
           <p>爱好:{{hobby}}</p>
    </div>
</template>
<script>
export default {
    props:{
        name:{
            type:String,
            required:true,
        },
        age:{
            type:[String,Number],
        },
        gender:{
            type:String,
            default:"男",
        },
        hobby:{
            type:Array,
            default(){
                return["阅读","旅游"];
            }
        }
    }
};
</script>
<style lang="">
    
</style>

